import { checkAuthReq } from '@/service/index';
import { useRequest } from 'umi';

export default () => {
  const { data, error, loading } = useRequest(() => checkAuthReq());
  if (loading) {
    return <div>正在加载...</div>;
  }
  if (error) {
    return <div>{error.message}</div>;
  }
  // console.log(data,'useAuth');
  
  return data
};